#pragma once

#include <QWidget>
#include "ui_torusWindow.h"
#include "modelSoft.h"

QT_BEGIN_NAMESPACE
namespace Ui { class torusWindowClass; };
QT_END_NAMESPACE

class torusWindow : public QWidget
{
	Q_OBJECT

public:
	torusWindow(modelSoft* myModelSoft,TorusFeature* m_torusFeature,QWidget *parent = nullptr);
	~torusWindow();

	double get_torus_radius1();
	double get_torus_radius2();

private slots:
	void makeTorus_onClick();

protected:
	void createConnections();
	virtual void closeEvent(QCloseEvent* event) override;
	void receivePos(const TopoDS_Shape& shape);
	void onClickVertexSelect();
	void onRadius1Changed();
	void onRadius2Changed();


private:
	Ui::torusWindowClass *ui;
	modelSoft* myModelSoft;
	gp_Pnt point_pos = gp_Pnt(0, 0, 0);
	Standard_Integer shapeID;
	TorusFeature* torusFeature;
	bool confirmCreate = false;
	bool edit = false;
	Handle(QIVtkSelectionPipeline) torusPipeline;
};
